package mylab.starters.dag.graph.impl;

import com.google.common.collect.Sets;

import java.util.Set;
import java.util.UUID;

import lombok.Getter;
import mylab.base.foundation.template.pojo.BaseStringIDPojo;
import mylab.starters.dag.graph.Edge;
import mylab.starters.dag.graph.Graph;
import mylab.starters.dag.graph.Vertex;

@Getter
public class BaseGraph extends BaseStringIDPojo implements Graph {

    protected Set<Vertex> vertices = Sets.newHashSet();
    protected Set<Edge> edges = Sets.newHashSet();

    public BaseGraph() {
        this(UUID.randomUUID().toString(), "default");
    }

    public BaseGraph(String id, String name) {
        this.id = id;
        this.name = name;
    }
}